<?php

//权限
$this->group(['domain' => env('DOMAIN_ADMIN'),'prefix' => 'config/permission'], function() {
    $this->get('/view/list', 'PermissionController@getLists');
	$this->get('/view/{id}', 'PermissionController@getOne')->where('id','[0-9]+');
	//获取所有权限
	$this->get('/view/tree', 'PermissionController@getTree');
	//验证权限路径唯一
	$this->get('/view/check/name','PermissionController@checkName');
	//新增
	$this->put('/insert', 'PermissionController@insertOne');
	//更新
	$this->post('/update', 'PermissionController@postOne');
	//删除
	$this->delete('/delete/{id}', 'PermissionController@deleteOne')->where('id','[0-9]+');
});
